# Contributor: Leo <thinkabit.ukim@gmail.com>
# Maintainer: Sodface <sod@sodface.com>
pkgname=libnpupnp
pkgver=6.1.1
pkgrel=0
pkgdesc="UPnP library based on libupnp, but extensively rewritten"
url="https://www.lesbonscomptes.com/upmpdcli/npupnp-doc/libnpupnp.html"
arch="all"
license="BSD-3-Clause"
makedepends="expat-dev curl-dev libmicrohttpd-dev"
subpackages="$pkgname-dev"
source="https://www.lesbonscomptes.com/upmpdcli/downloads/libnpupnp-$pkgver.tar.gz"

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--localstatedir=/var
	make
}

check() {
	make check
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="
905c0dfc7f018a80380406682550271893d795a1964bb5e7c4a56c6934ce06b9b6e29a2c5a7a9c4bf1a5a2348637ad6af3fd99cd38d7bba9d935fdbec6a6dce5  libnpupnp-6.1.1.tar.gz
"
